#include<iostream>
using namespace std;

namespace test2 {
	void foo() {
		static int fooA = 0;
		fooA++;
		cout << "fooA called " << fooA << " times" << endl;
	}

	static int golbalVar = 33;

	static class Sa {
	public:
		static int a;
		static void foo() {
			cout << "Sa::foo()" << endl;
		}
	};

	int Sa::a = 0;

	int main() {
		foo();
		foo();
		foo();

		cout << "Global var:" << golbalVar << endl;

		Sa sa1;
		Sa sa2;
		sa1.a = 1;
		sa2.a = 2;
		cout << "sa1.a=" << sa1.a << endl;
		cout << "sa2.a=" << sa2.a << endl;
		cout << "class Sa.a=" << Sa::a << endl;

		return 0;
	}
}